﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Cherry.Agile.Logging
{
    /// <summary>
    /// 日志的接口定义
    /// </summary>
    public interface ILogger
    {
        /// <summary>
        /// 记录调试信息
        /// </summary>
        /// <param name="message">调试信息</param>
        void Debug(string message);

        /// <summary>
        /// 记录一般信息
        /// </summary>
        /// <param name="message">一般信息</param>
        void Info(string message);

        /// <summary>
        /// 性能告警
        /// </summary>
        /// <param name="message"></param>
        void PerforemanceWarn(string message);

        /// <summary>
        /// 记录错误信息
        /// </summary>
        /// <param name="message">错误信息</param>
        void Error(string message);

        /// <summary>
        /// 记录错误和异常信息
        /// </summary>
        /// <param name="message">错误信息</param>
        /// <param name="ex">异常</param>
        void Error(string message, System.Exception ex);

        /// <summary>
        /// 记录警告信息
        /// </summary>
        /// <param name="message">警告信息</param>
        void Warn(string message);

        /// <summary>
        /// 记录致命错误信息
        /// </summary>
        /// <param name="message">致命错误信息</param>
        void Fatal(string message);

        /// <summary>
        /// Sql跟踪日志
        /// </summary>
        /// <param name="message"></param>
        void SqlTrace(string message);
    }
}
